using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._TopographicProductionTools._Cartography._Features
{
    /// <summary>
    /// <para>Generate Elevation Guide Features</para>
    /// <para>Creates data required for an elevation guide diagram 
    /// surround element as required by various supported map product specifications.  This tool leverages existing 
    /// banding 
    /// and thinning tools to generate output elevation band features, spot height features, and 
    /// hydrology features.</para>
    /// <para>创建高程参考线图所需的数据
    /// 各种支持的地图产品规格所要求的环绕元素。 该工具利用现有的
    /// 带
    /// 以及用于生成输出高程带要素、光斑高度要素和
    /// 水文特征。</para>
    /// </summary>    
    [DisplayName("Generate Elevation Guide Features")]
    public class GenerateElevationGuideFeatures : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public GenerateElevationGuideFeatures()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_feature_dataset">
        /// <para>Input Feature Dataset</para>
        /// <para>An existing feature dataset that will contain the EGB feature classes. Data created for the elevation guide box is maintained in these feature classes in this feature dataset.</para>
        /// <para>将包含 EGB 要素类的现有要素数据集。为高程指南框创建的数据将保留在此要素数据集的这些要素类中。</para>
        /// </param>
        /// <param name="_area_of_interest">
        /// <para>Area Of Interest</para>
        /// <para>A feature layer with a single selected feature that defines a processing extent for banding operations and a clipping extent for spot heights, input hydro areas, and lines.</para>
        /// <para>具有单个选定要素的要素图层，用于定义条带操作的处理范围以及光斑高度、输入水文区域和线的裁剪范围。</para>
        /// </param>
        /// <param name="_in_rasters">
        /// <para>Input Rasters</para>
        /// <para>One or more rasters used to create elevation bands and supply elevation values to features created by the tool.</para>
        /// <para>一个或多个栅格，用于创建高程带并向工具创建的要素提供高程值。</para>
        /// </param>
        public GenerateElevationGuideFeatures(object _in_feature_dataset, object _area_of_interest, List<object> _in_rasters)
        {
            this._in_feature_dataset = _in_feature_dataset;
            this._area_of_interest = _area_of_interest;
            this._in_rasters = _in_rasters;
        }
        public override string ToolboxName => "Topographic Production Tools";

        public override string ToolName => "Generate Elevation Guide Features";

        public override string CallName => "topographic.GenerateElevationGuideFeatures";

        public override List<string> AcceptEnvironments => [];

        public override object[] ParameterInfo => [_in_feature_dataset, _area_of_interest, _in_rasters, _hydro_exclusion_features, _spot_height_features, _hydro_line_features, _hydro_area_features, _contour_interval, _bands_minarea, _smooth_tolerance, _number_of_bands, _height_field, _search_distance, _hydroline_minlength, _hydroline_minspacing, _hydroarea_minlength, _hydroarea_minwidth, _out_feature_dataset];

        /// <summary>
        /// <para>Input Feature Dataset</para>
        /// <para>An existing feature dataset that will contain the EGB feature classes. Data created for the elevation guide box is maintained in these feature classes in this feature dataset.</para>
        /// <para>将包含 EGB 要素类的现有要素数据集。为高程指南框创建的数据将保留在此要素数据集的这些要素类中。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Feature Dataset")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_feature_dataset { get; set; }


        /// <summary>
        /// <para>Area Of Interest</para>
        /// <para>A feature layer with a single selected feature that defines a processing extent for banding operations and a clipping extent for spot heights, input hydro areas, and lines.</para>
        /// <para>具有单个选定要素的要素图层，用于定义条带操作的处理范围以及光斑高度、输入水文区域和线的裁剪范围。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Area Of Interest")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _area_of_interest { get; set; }


        /// <summary>
        /// <para>Input Rasters</para>
        /// <para>One or more rasters used to create elevation bands and supply elevation values to features created by the tool.</para>
        /// <para>一个或多个栅格，用于创建高程带并向工具创建的要素提供高程值。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Rasters")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public List<object> _in_rasters { get; set; }


        /// <summary>
        /// <para>Hydro Exclusion Features</para>
        /// <para>A feature layer that defines a large water body area to exclude from the elevation band area computation.</para>
        /// <para>定义要从高程带区域计算中排除的大水体区域的要素图层。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Hydro Exclusion Features")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _hydro_exclusion_features { get; set; } = null;


        /// <summary>
        /// <para>Spot Height Features</para>
        /// <para>A feature layer or class that contains spot heights.</para>
        /// <para>包含光斑高度的要素图层或类。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Spot Height Features")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _spot_height_features { get; set; } = null;


        /// <summary>
        /// <para>Hydro Line Features</para>
        /// <para>Hydrology line features used to generate the output of a thinned hydrology dataset. Only the output features are generalized through this thinning process.</para>
        /// <para>用于生成细化水文数据集输出的水文线要素。只有输出特征通过此稀疏过程进行泛化。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Hydro Line Features")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _hydro_line_features { get; set; } = null;


        /// <summary>
        /// <para>Hydro Area Features</para>
        /// <para>Hydrology area features used to generate the thinned hydrology dataset. Only the output features are generalized through this thinning process.</para>
        /// <para>用于生成细化水文数据集的水文区域要素。只有输出特征通过此稀疏过程进行泛化。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Hydro Area Features")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public List<object> _hydro_area_features { get; set; } = null;


        /// <summary>
        /// <para>Contour Interval</para>
        /// <para><xdoc>
        ///   <para>The contour interval used to determine the closest available contour when calculating the elevation band area. Elevation bands are created with their limits aligned to the chosen contour interval, except low and high values, which will represent their actual calculated values.</para>
        ///   <bulletList>
        ///     <bullet_item>10—A contour interval of 10 will be used.</bullet_item><para/>
        ///     <bullet_item>20—A contour interval of 20 will be used. This is the default.</bullet_item><para/>
        ///     <bullet_item>40—A contour interval of 40 will be used.</bullet_item><para/>
        ///     <bullet_item>80—A contour interval of 80 will be used.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>计算高程带面积时用于确定最近可用等值线的等值线间隔。创建高程带时，其极限与所选等值线间隔对齐，但低值和高值除外，它们将表示其实际计算值。</para>
        ///   <bulletList>
        ///     <bullet_item>10 - 将使用 10 的等值线间隔。</bullet_item><para/>
        ///     <bullet_item>20—将使用 20 的等值线间隔。这是默认设置。</bullet_item><para/>
        ///     <bullet_item>40—将使用 40 的等值线间隔。</bullet_item><para/>
        ///     <bullet_item>80—将使用等值线间隔 80。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Contour Interval")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public long _contour_interval { get; set; } = 20;


        /// <summary>
        /// <para>Minimum Feature Area</para>
        /// <para><xdoc>
        ///   <para>The minimum area for output polygons. Features smaller than this value will be removed. The default is 0.00016 square decimal degrees.
        ///   <para>If you are creating an output dataset with a projected coordinate system, ensure that this value reflects the square units of that coordinate system—for example, square meters for a UTM dataset. Otherwise, the default value may result in an empty output dataset.</para>
        ///   </para>
        /// </xdoc></para>
        /// <para><xdoc>
        /// <para>输出面的最小面积。小于此值的要素将被移除。默认值为 0.00016 平方十进制度。
        ///   <para>如果要创建具有投影坐标系的输出数据集，请确保此值反映该坐标系的平方单位，例如，UTM 数据集的平方米。否则，默认值可能会导致输出数据集为空。</para>
        ///   </para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Minimum Feature Area")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public double _bands_minarea { get; set; } = 0.00016;


        /// <summary>
        /// <para>Smoothing Tolerance</para>
        /// <para>The tolerance used by the smoothing algorithm. The larger the value, the more generalized the output band features. The default is 0.002 decimal degrees.</para>
        /// <para>平滑算法使用的容差。该值越大，输出频带特征越通用。默认值为 0.002 十进制度。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Smoothing Tolerance")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string _smooth_tolerance { get; set; } = "0.002 DecimalDegrees";


        /// <summary>
        /// <para>Number Of Elevation Bands</para>
        /// <para><xdoc>
        ///   <para>Specifies the number of elevation bands that will be generated.</para>
        ///   <bulletList>
        ///     <bullet_item>1—One elevation band will be generated.</bullet_item><para/>
        ///     <bullet_item>2—Two elevation bands will be generated.</bullet_item><para/>
        ///     <bullet_item>3—Three elevation bands will be generated.</bullet_item><para/>
        ///     <bullet_item>4—Four elevation bands will be generated.</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para><xdoc>
        ///   <para>指定将生成的高程带数。</para>
        ///   <bulletList>
        ///     <bullet_item>1 - 将生成一个高程带。</bullet_item><para/>
        ///     <bullet_item>2 - 将生成两个高程带。</bullet_item><para/>
        ///     <bullet_item>3 - 将生成三个高程带。</bullet_item><para/>
        ///     <bullet_item>4 - 将生成四个高程带。</bullet_item><para/>
        ///   </bulletList>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Number Of Elevation Bands")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public long? _number_of_bands { get; set; } = null;


        /// <summary>
        /// <para>Height Field</para>
        /// <para>The field that identifies the elevation values of the spot height features. These values will be evaluated during the thinning process.</para>
        /// <para>用于标识点高度要素的高程值的字段。这些值将在疏伐过程中进行评估。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Height Field")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _height_field { get; set; } = null;


        /// <summary>
        /// <para>Search Distance</para>
        /// <para>The minimum distance between spot heights. The default is 0 meters.</para>
        /// <para>光斑高度之间的最小距离。默认值为 0 米。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Search Distance")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string _search_distance { get; set; } = "0 Meters";


        /// <summary>
        /// <para>Minimum Hydro Line Length</para>
        /// <para>The minimum length used to eliminate hydrographic features. The tool will thin hydro features that have a length less than this value. This value is used when generalizing input hydro lines and areas.</para>
        /// <para>用于消除水文要素的最小长度。该工具将对长度小于此值的水文要素进行细化。此值用于概括输入水力管线和区域。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Minimum Hydro Line Length")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _hydroline_minlength { get; set; } = null;


        /// <summary>
        /// <para>Minimum Hydro Line Spacing</para>
        /// <para>The shortest distance between a hydrographic segment that is sensible to display at the output scale. If the spacing between two parallel trending features is smaller than this value, one of the features will be set as invisible. It defines a sense of the density of the resulting thinned hydrography. It should correspond to the distance between two parallel trending features that is visually significant to include at the final scale. When the density of features is too high (that is, the features are too closely spaced), at least one feature will be hidden. This can result in important features or features longer than the Minimum Hydro Line Length value being hidden.</para>
        /// <para>在输出比例下可合理显示的水文线段之间的最短距离。如果两个平行趋势要素之间的间距小于此值，则其中一个要素将被设置为不可见。它定义了由此产生的稀疏水文的密度感。它应对应于两个平行趋势要素之间的距离，该距离在最终比例中具有视觉意义。当要素密度过高（即要素间距太近）时，至少会隐藏一个要素。这可能导致隐藏重要要素或长于最小水线长度值的特征。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Minimum Hydro Line Spacing")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _hydroline_minspacing { get; set; } = null;


        /// <summary>
        /// <para>Minimum Hydro Area Length</para>
        /// <para>The length used to split and classify hydrographic polygons as short or long. Polygons will be split at any location where the edge-to-edge distance is equal to the Minimum Hydro Area Length value.</para>
        /// <para>用于将水文面分割和分类为短或长的长度。多边形将在边到边距离等于最小水文面积长度值的任何位置进行分割。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Minimum Hydro Area Length")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _hydroarea_minlength { get; set; } = null;


        /// <summary>
        /// <para>Minimum Hydro Area Width</para>
        /// <para>The width used to split and classify hydrographic polygons as narrow or wide. Polygons will be split at any location where the edge-to-edge distance is equal to the Minimum Hydro Area Width value.</para>
        /// <para>用于将水文面分割和分类为窄或宽的宽度。多边形将在边到边距离等于最小水力面积宽度值的任何位置进行分割。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Minimum Hydro Area Width")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public string? _hydroarea_minwidth { get; set; } = null;


        /// <summary>
        /// <para>Modified Feature Dataset</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Modified Feature Dataset")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_feature_dataset { get; set; }


        public GenerateElevationGuideFeatures SetEnv()
        {
            base.SetEnv();
            return this;
        }

    }

}